package com.constructiveproof.example

import org.scalatra._
import scalate.ScalateSupport
import com.constructiveproof.example.auth.AuthenticationSupport
import com.constructiveproof.example.models.User

class ProtectedController extends ScentryauthdemoStack with AuthenticationSupport {

  /**
   * 执行验证身份
   */
  before() {
    requireLogin()
  }

  get("/") {
  
    println(userOption)
    println(userOption)
  
    <h1>"这是一个受保护的控制器动作。如果你能看到它，你就登录了。欢迎你"</h1>
  }
}




